﻿using System;
using System.Windows.Input;
using System.Windows.Navigation;
using Microsoft.Phone.Controls;

namespace Alcomether.Controlers.Setting
{
    public class SettingsControler
    {
        public ICommand SaveButton { get; set; }

        public SettingsControler()
        {
            SaveButton = new SaveHelper(this);
        }

        public void Save()
        {
           InvokeNavigateToEventHandler(new EventArgs());
        }

        public event EventHandler NavigateToEventHandler;

        private void InvokeNavigateToEventHandler(EventArgs e)
        {
            EventHandler handler = NavigateToEventHandler;
            if (handler != null)
            {
                handler(this,e);
            }
        }

        public int Weight { get; set; }
    }
}
